package fr.emse.tatiana;

import org.eclipse.core.resources.IFile;
import org.eclipse.core.resources.ResourcesPlugin;

import fr.emse.tatiana.display.PropertyFile;

/**
 * Singleton class where configuration values are stored
 * 
 * @author dyke
 *
 */
public class TatianaConfig extends PropertyFile {
	
	private static TatianaConfig instance;
	public static TatianaConfig getInstance() {
		if (instance==null) {
			// TODO choose a place where it won't get overwritten!
			IFile metadata = ResourcesPlugin.getWorkspace().getRoot().getProject("Tatiana").getFile("tatiana.metadata");
			instance = new TatianaConfig(metadata);
		}
		return instance;
	}

	private TatianaConfig(IFile file) {
		super(file);
	}
	
}
